#coding=utf-8

# 计算积分x^2

import numpy as np


def intergate_numpy(start, stop):
    length = 1000000
    x = np.linspace(start, stop, length)
    y = 3*x**2
    result = sum(y*(stop-start)/length)
    return result
